package core.sceneManager.sceneSection
{
	import flash.events.EventDispatcher;
	import flash.events.IEventDispatcher;
	/**
	 * 场景模块
	 */ 
	public class SceneSection extends EventDispatcher implements ISceneSection
	{
		protected var dataBase:XML;                        //数据库，根据数据库创建模块
		protected var type:String;                         //模块的类型s
		protected var sectionName:String;                  //模块的名字
		public function SceneSection(target:IEventDispatcher=null)
		{
			super(target);
		}
		/**
		 * 根据XML创建属性
		 */ 
		public function excute(xml:XML, container:*):void
		{
			this.dataBase=xml;
			for each(var item:XML in xml.attributes())
			{
				var key:String=item.name();
				this[key]=item.toString();
			}
		}
		/**
		 * 开始创建模块
		 */ 
		public function start():void
		{
		}
		/**
		 * 回收内存
		 */ 
		public function dispose():void
		{
			this.dataBase=null;
			this.type=null;
			this.sectionName=null;
		}
		override public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void
		{
			super.addEventListener(type,listener,useCapture,priority,useWeakReference);
		}
		
		override public function removeEventListener(type:String, listener:Function, useCapture:Boolean=false):void
		{
			super.removeEventListener(type,listener,useCapture);
		}
		protected function set autoRefresh(val:int):void{}
	}
}